home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / easydr2.zip / EASYANSI.BI < prev    next >
Text File  |  1991-11-15  |  2KB  |  47 lines

  1. ' ANSI COLOR SUPPORT MODULE for Easy-Door V2.0b
  2. '
  3. ' This module includes all the code to use ANSI escape sequence
  4. ' in your program without pain. If user do not have ANSI, variables
  5. ' will be set to an empty string ("").
  6.  
  7. ' Example:
  8. '
  9. ' CALL SendCR(Bright$ + Yellow$ + "Welcome to this DOOR!")
  10. '
  11. ' Important: If you use too much color in your program, the display will be
  12. '            slow and, of course, not acceptable for the user.
  13. '            Five characters are needed to send a simple ANSI color code.
  14.  
  15. IF AnsiFlag$ > "0" THEN
  16.  
  17. AnsiReset$ = ""          ' Put all mode to off, reset
  18. Blink$ = ""              ' Put in blinking mode
  19. Invert$ = ""             ' Put in reverse video mode
  20. Bright$ = ""             ' Put in high intensity mode (bright)
  21. Down$ ="B"                ' Cursor one line down
  22. Up$ = "A"                 ' Cursor one line up
  23. SavePos$ = "s"             ' Save current cursor position
  24. RestorePos$ = "u"          ' Restore cursor position
  25. AnsiCLS$ = ""            ' ANSI Clear screen sequence
  26. EraseLine$ = ""           ' Erase current line
  27.  
  28. Black$ = ""             '
  29. Red$ = ""               '
  30. Green$ = ""             '
  31. Yellow$ = ""            ' Foreground text color
  32. Blue$ = ""              '
  33. Magenta$ = ""           '
  34. Cyan$ = ""              '
  35. White$ = ""             '
  36.  
  37. BlackBack$ = ""         '
  38. RedBack$ = ""           '
  39. GreenBack$ = ""         '
  40. YellowBack$ = ""        ' Background text color
  41. BlueBack$ = ""          '
  42. MagentaBack$ = ""       '
  43. CyanBack$ = ""          '
  44. WhiteBack$ = ""         '
  45.  
  46. END IF
  47.